<form [formGroup]="myForm" (ngSubmit)="onSubmit()" class="example-form">
  <mat-form-field class="example-full-width" appearance="fill">
    <mat-label>Title</mat-label>
    <input matInput formControlName="title">
  </mat-form-field>
  <mat-form-field class="example-full-width" appearance="fill">
    <mat-label>Price</mat-label>
    <input matInput formControlName="price">
  </mat-form-field>
  <mat-form-field class="example-full-width" appearance="fill">
    <mat-label>Description</mat-label>
    <input matInput formControlName="description">
  </mat-form-field>
 
 
  
  


  <button class="button" mat-flat-button style="margin-right: 2px" color="primary" type="submit">
    {{isNew ? 'Добавить Товар' : 'Обновить'}}</button>
  <button class="button" mat-flat-button color="primary" (click)="onNoClick()" type="button">Отмена</button>


</form>
